#!/usr/bin/env python
# -*- encoding: utf-8 -*-
'''
@File    :   screenshot.py
@Time    :   2024/02/09 02:13:12
@Author  :   chakcy 
@Email   :   947105045@qq.com
@description   :   截图模块
'''

import pyautogui
# 截图

def screenshot(img_path, region=None):
    if region is None:
        img = pyautogui.screenshot()
    img = pyautogui.screenshot(region)
    img.save(img_path)